<?php
namespace Gotcha\Core\Components\DependencyFactory {
    use Gotcha\Core\Components\Debugging\Debugger;
    use Gotcha\Core\Components\Debugging\Logger;
    use Gotcha\Core\Components\DependencyFactory\Interfaces\IDependencyFactory;
    use Gotcha\Core\Components\DTO\AppConfig;
    use Gotcha\Core\Components\Localization\CultureInfo;
    use Gotcha\Core\Components\XML\XMLReader;

    class DependencyFactory implements IDependencyFactory {
        public static function createSelf()
        {
            return new self;
        }

        public static function createXMLReader()
        {
            return new XMLReader();
        }

        public static function createDebugger()
        {
            return new Debugger(self::createLogger());
        }

        static function createLogger()
        {
           return new Logger();
        }

        static function createDTOAppConfig() {
            return new AppConfig();
        }

        static function createCultureInfo()
        {
            return new CultureInfo(self::createDTOAppConfig());
        }
    }
}

